import type { TableConfig } from '@/api/config/types';
//查询参数接口
interface dataQuery {
  dictType: string;
  status: string;
}
let queryObj = {
  pageNum: 1,
  pageSize: 10,
  total: 0,
  status: '',
  dictType: '',
};

const resetQuery = () => {
  dataTable.value.query = {
    ...queryObj,
  };
};

export const dataTable = ref<TableConfig<SystemDictData>>({
  //作用：勾选的唯一标识
  rowKey: 'dictCode',
  data: [],
  loading: false,
  moduleName: 'data',
  viewMode: 'table',
  keys: [],
  query: queryObj,
  contextmenu: [],
  reset: resetQuery,
});

// 已选中的元素数组
export const dataKeys = ref<number[]>([]);
